package tw.rescue.action;

import tw.rescue.dao.GuestBookDao;
import tw.rescue.dao.impl.slim3.QueryStateHolder;
import tw.rescue.slim3.model.GuestBookMessage;

import com.google.appengine.api.datastore.Key;

public class GuestBookMessageAction {
	private GuestBookDao<Key, QueryStateHolder<GuestBookMessage>> dao;
	
	public void setGuestBookDao(GuestBookDao<Key, QueryStateHolder<GuestBookMessage>> dao) {
		this.dao = dao;
	}
	
	public GuestBookMessageAction() {
		System.out.println("new action!!");
	}
	
	public String guestbook_form() throws Exception {
		System.out.println("dao是null? " + (dao == null));
		return "guestbook_form";
	}
	
	public String guestbook_new() throws Exception {
		System.out.println("dao是null? " + (dao == null));
		return "guestbook_new";
	}
	
	public String guestbook_reply() throws Exception {
		System.out.println("dao是null? " + (dao == null));
		return "guestbook_reply";
	}
	
	public String guestbook_list_message() throws Exception {
		System.out.println("dao是null? " + (dao == null));
		return "guestbook_list_message";
	}
	
	public String guestbook_view_message() throws Exception {
		System.out.println("dao是null? " + (dao == null));
		return "guestbook_view_message";
	}
}
